<form id="pagerForm" method="post" action="<?php echo $this->url('system',array('controller'=>'user','action'=>'showUserList'));?>?Action=selectLeader">
	<input type="hidden" name="pageNum" value="1" />
	<input type="hidden" name="numPerPage" value="<?php echo $numPerPage;?>" />
	<input type="hidden" name="userId" value="<?php echo $userId;?>" />
	<input type="hidden" name="nameStr" value="<?php echo $nameStr;?>" />
	<input type="hidden" name="departmentId" value="<?php echo $departmentId;?>" />
</form>

<div class="pageHeader">
    <form onsubmit="return dwzSearch(this, 'dialog');" action="<?php echo $this->url('system',array('controller'=>'user','action'=>'showUserList'));?>?Action=selectLeader" method="post">
    <div class="searchBar">
        <table class="searchContent">
        <tr>
            <td>
                                                           用户ID：<input type="text" name="userId" value="<?php if($userId):echo $userId;endif;?>"/>
            </td>
            <td>
                                                           用户名称：<input type="text" name="nameStr" value="<?php echo $nameStr;?>"/>
            </td>
            <td>
                                                        所在部门：
				
				<select name="departmentId" >
				        <option value="">请选择部门</option>
				    <?php foreach ($departmentList as $key=>$department):?>
				        <option value="<?php echo $key;?>" <?php if($key==$departmentId): echo 'selected="selected"'; endif;?>><?php echo $department;?></option>
				    <?php endforeach;?>
				</select>
				
            </td>
            <td>
                <div class="buttonActive"><div class="buttonContent"><button type="submit">点击查询</button></div></div>
 				<div class="button"><div class="buttonContent"><button type="button" multLookup="leaderId" warn="请选择领导">选择领导</button></div></div>           
            </td>
        </tr>
        </table>
		<div class="subBar">
		<ul>
            <li></li>
        </ul>
		</div>
    </div>
    </form>
</div>
<div class="pageContent">
	<table class="table" width="99%"  layoutH="138" targetType="dialog">
		<thead>
			<tr>
			    <th width="5%"><input type="checkbox" class="checkboxCtrl" group="leaderId" /></th>
				<th width="15%">用户ID</th>
				<th width="25%">用户名</th>
				<th width="30%">所在部门</th>
				<th width="25%">创建时间</th>
				
			</tr>
		</thead>
		<tbody>
		    <?php foreach ($userList as $user):?>
			<tr >
			    <td><input type="checkbox" name="leaderId" value="{user_id:'<?php echo $user['id'];?>',user_name:'<?php echo $user['realname'];?>'}" /></td>
				<td><?php echo $user['id'];?></td>
				<td><?php echo $user['realname'];?></td>
				<td><?php echo $user['department_name'];?></td>
				<td><?php echo $user['add_time'];?></td>
			</tr>
		    <?php endforeach;?>
		</tbody>
	</table>
	<div class="panelBar">
		<div class="pages">
			<span>显示</span>
			<select class="combox" name="numPerPage" onchange="dwzPageBreak({targetType:dialog,numPerPage:this.value})">
				<option value="20" <?php if ($numPerPage==20): echo 'selected="selected"';endif;?>>20</option>
				<option value="50" <?php if ($numPerPage==50): echo 'selected="selected"';endif;?>>50</option>
				<option value="100" <?php if ($numPerPage==100): echo 'selected="selected"';endif;?>>100</option>
				<option value="200" <?php if ($numPerPage==200): echo 'selected="selected"';endif;?>>200</option>
			</select>
			<span>条，共<?php echo $totalCount;?>条</span>
		</div>		
		<div class="pagination" 
		    targetType="dialog"
		    totalCount="<?php echo $totalCount;?>" 
		    numPerPage="<?php echo $numPerPage;?>" 
		    pageNumShow="<?php echo $pageNumShow;?>" 
		    currentPage="<?php echo $pageNum;?>">
		</div>
	</div>
</div>